import request from "@/common/js/request.js";
import requestJson from "@/common/js/requestJson.js";

const api = {
    login: (code) => {
        return request({
            url: "/login",
            method: "post",
            data: { code },
        });
    },
    test_login: (code) => {
        return request({
            url: "/test_login",
            method: "post",
            data: { code },
        });
    },

    leads_status_status: (params) => {
        return request({
            url: "/leads_status_status",
            method: "post",
            data: params,
        });
    },
    laeds_status_lists: (params) => {
        return request({
            url: "/laeds_status_lists",
            method: "post",
            data: params,
        });
    },
    // 问题类型
    cates: (params) => {
        return request({
            url: "/help/cates",
            method: "post",
            data: params,
        });
    },
    // 新建问题
    store: (params) => {
        return request({
            url: "/help/store",
            method: "post",
            data: params,
        });
    },
    // 问题列表
    helps: (params) => {
        return request({
            url: "/help/helps",
            method: "post",
            data: params,
        });
    },
    // 信息中心分类
    infoCates: (params) => {
        return request({
            url: "/info/cates",
            method: "post",
            data: params,
        });
    },
    // 信息中心列表
    infos: (params) => {
        return request({
            url: "/info/infos",
            method: "post",
            data: params,
        });
    },
    // 活动列表
    activities: (params) => {
        return request({
            url: "/activity/activities",
            method: "post",
            data: params,
        });
    },
    // 上传活动图片
    upload: (params) => {
        return request({
            url: "/activity/upload",
            method: "post",
            data: params,
        });
    },
    // 发布活动
    activityStore: (params) => {
        return request({
            url: "/activity/store",
            method: "post",
            data: params,
        });
    },
    // 部门接口
    departments: (params) => {
        return request({
            url: "/department/departments",
            method: "post",
            data: params,
        });
    },
    // 通讯录搜索人员
    member: (params) => {
        return request({
            url: "/member",
            method: "post",
            data: params,
        });
    },
    // wx sdk
    js_config: (params) => {
        return request({
            url: "/js_config",
            method: "post",
            data: params,
        });
    },
    // 业绩报告 ，普通用户
    yjbg: (params) => {
        return request({
            url: "report/yjbg",
            method: "post",
            data: params,
        });
    },
    // 业绩报告 totalLead
    totalLead: (params) => {
        return request({
            url: "report/totalLead",
            method: "post",
            data: params,
        });
    },
    // 业绩报告 definiteLead
    definiteLead: (params) => {
        return request({
            url: "report/definiteLead",
            method: "post",
            data: params,
        });
    },
    // 业绩报告 type2yjbg
    type2yjbg: (params) => {
        return request({
            url: "report/type2yjbg",
            method: "post",
            data: params,
        });
    },
    // 业绩报告 topseller
    topseller: (params) => {
        return request({
            url: "report/topseller",
            method: "post",
            data: params,
        });
    },
    // 业绩报告 senderHotel
    senderHotel: (params) => {
        return request({
            url: "report/senderHotel",
            method: "post",
            data: params,
        });
    },
    // 业绩报告 receivingHotel
    receivingHotel: (params) => {
        return request({
            url: "report/receivingHotel",
            method: "post",
            data: params,
        });
    },
    //酒店列表
    hotels: (params) => {
        return request({
            url: "user_info",
            method: "post",
            data: params,
        });
    },
};

export default api;
